﻿@model ShoppingCartVM
@{
    ViewBag.Title = "下单支付";

    var Address = (SIG.Model.Shipping.RecipientInfo)ViewBag.Address;
}

<div class="container page-payment">
    <div class="container-fluid">
        <div class="row wizard">
            <div class="col-xs-4 ">
                购物车
            </div>
            <div class="col-xs-4">
                填写收件地址
            </div>
            <div class="col-xs-4 active">
                下单支付
            </div>
        </div>
    </div>

  <div class="row">
      <div class="col-sm-5">
          <div class="well">
              <ul class="list-unstyled">
                  <li>地址：@Address.ProvinceName @Address.CityName @Address.DistrictName @Address.Address</li>
                  <li>收件人：@Address.Recipient</li>
                  <li>手机：@Address.Mobile</li>
                  <li>电话：@Address.Phone</li>
                  <li>邮编：@Address.Postcode</li>
              </ul>
          </div>
      </div>
      <div class="col-sm-7">
          <div class="well">
              <table class="table table-hover table-vmiddle">
                  <thead>
                      <tr>
                          <th>
                              品名
                          </th>
                          <th>
                              价格
                          </th>
                          <th>
                              数量
                          </th>
                          <th></th>
                      </tr>
                  </thead>
                  <tbody>
                      @foreach (var item in Model.CartItems)
                      {
                          <tr id="row-@item.Id">
                              <td>
                                  @Html.ActionLink(item.Goods.Name, "Details", "Store", new { id = item.GoodsId }, null)
                              </td>
                              <td>
                                  @item.Goods.Price
                              </td>
                              <td id="item-count-@item.Id">
                                  @item.Count
                              </td>
                              <td>
                                  <a href="#" class="RemoveLink btn btn-default btn-sm"
                                     data-id="@item.Id">
                                      移除
                                  </a>
                              </td>
                          </tr>
                      }
                  </tbody>
                  <tfoot>
                      <tr>
                          <td colspan="3" class="text-right">
                              合计
                          </td>
                          <td>
                              <strong id="cart-total">@Model.CartTotal</strong>
                          </td>
                      </tr>
                  </tfoot>
              </table>
          </div>
      </div>
  </div>
       
    <div class="container-fluid text-center">
        @Html.ActionLink("去支付", "SetAddress", null, new { @class = "btn btn-primary" })
    </div>
</div>